﻿<?xml version="1.0" encoding="utf-8"?>
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:c4fConverters="using:Coding4Fun.Toolkit.Controls.Converters" xmlns:local="using:Coding4Fun.Toolkit.Controls">
  <!--WindowsStore-->
  <ResourceDictionary.ThemeDictionaries>
    <ResourceDictionary x:Key="Default" />
    <ResourceDictionary x:Key="Light" />
    <ResourceDictionary x:Key="HighContrast" />
  </ResourceDictionary.ThemeDictionaries>
  <c4fConverters:SolidColorBrushToColorConverter x:Key="BrushToBrush" />
  <SolidColorBrush x:Key="DefaultAccentBrush" Color="#0050EF" />
  <SolidColorBrush x:Key="DefaultChromeBrush" Color="#1F1F1F" />
  <SolidColorBrush x:Key="DefaultBackgroundBrush" Color="#000000" />
  <SolidColorBrush x:Key="DefaultForegroundBrush" Color="#FFFFFF" />
  <SolidColorBrush x:Key="DefaultSubtleBrush" Color="#99FFFFFF" />
  <SolidColorBrush x:Key="DefaultDisabledBrush" Color="#6FFF" />
  <SolidColorBrush x:Key="DefaultContrastDisabledBrush" Color="#1F1F1F" />
  <x:Double x:Key="DefaultFontSizeExtraSmall">12</x:Double>
  <x:Double x:Key="DefaultFontSizeNormal">20</x:Double>
  <x:Double x:Key="DefaultFontSizeMedium">22.667</x:Double>
  <x:Double x:Key="DefaultFontSizeMediumLarge">25.333</x:Double>
  <x:Double x:Key="DefaultFontSizeLarge">32</x:Double>
  <FontFamily x:Key="FontFamilySegoeNormal">Segoe UI</FontFamily>
  <FontFamily x:Key="FontFamilySegoeSemiBold">Segoe UI Semibold</FontFamily>
  <FontFamily x:Key="FontFamilySegoeSemiLight">Segoe UI SemiLight</FontFamily>
  <x:Double x:Key="DefaultAppButtonSize">72</x:Double>
  <x:Double x:Key="DefaultTileSize">173</x:Double>
  <Thickness x:Key="DefaultTextBoxInnerMargin">1,2</Thickness>
  <Thickness x:Key="DefaultBorderThickness">3</Thickness>
  <SolidColorBrush x:Key="DefaultTextBoxBrush" Color="{Binding Source={StaticResource TextBoxBackgroundThemeBrush}, Converter={StaticResource BrushToBrush}}" />
  <SolidColorBrush x:Key="DefaultTextBoxForegroundBrush" Color="{Binding Source={StaticResource TextBoxForegroundThemeBrush}, Converter={StaticResource BrushToBrush}}" />
  <SolidColorBrush x:Key="DefaultTextBoxReadOnlyBrush" Color="{Binding Source={StaticResource DefaultSubtleBrush}, Converter={StaticResource BrushToBrush}}" />
  <SolidColorBrush x:Key="DefaultTextBoxEditBackgroundBrush" Color="{Binding Source={StaticResource DefaultChromeBrush}, Converter={StaticResource BrushToBrush}}" />
  <SolidColorBrush x:Key="DefaultTextBoxEditBorderBrush" Color="{Binding Source={StaticResource DefaultAccentBrush}, Converter={StaticResource BrushToBrush}}" />
  <ControlTemplate x:Key="DisabledChatBubbleTextBoxTemplate" TargetType="TextBox">
    <ContentControl x:Name="ContentElement" BorderThickness="0" Margin="{TemplateBinding Margin}" HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}" Padding="{TemplateBinding Padding}" VerticalContentAlignment="{TemplateBinding VerticalContentAlignment}" />
  </ControlTemplate>
  <Style x:Key="AppBarText" TargetType="ContentControl">
    <Setter Property="HorizontalAlignment" Value="Center" />
    <Setter Property="Margin" Value="0" />
  </Style>
  <Style TargetType="local:ImageTile">
    <Setter Property="Background" Value="{StaticResource DefaultAccentBrush}" />
    <Setter Property="Foreground" Value="{StaticResource DefaultForegroundBrush}" />
    <Setter Property="FontFamily" Value="{StaticResource FontFamilySegoeSemiBold}" />
    <Setter Property="FontSize" Value="{StaticResource DefaultFontSizeNormal}" />
    <Setter Property="Margin" Value="10" />
    <Setter Property="Padding" Value="10,0" />
    <Setter Property="VerticalAlignment" Value="Top" />
    <Setter Property="HorizontalAlignment" Value="Right" />
    <Setter Property="MinWidth" Value="36" />
    <Setter Property="MinHeight" Value="36" />
    <Setter Property="Width" Value="{StaticResource DefaultTileSize}" />
    <Setter Property="Height" Value="{StaticResource DefaultTileSize}" />
    <Setter Property="Template">
      <Setter.Value>
        <ControlTemplate TargetType="local:ImageTile">
          <Grid Width="{TemplateBinding Width}" Height="{TemplateBinding Height}" Background="{TemplateBinding Background}">
            <Grid x:Name="ImageContainer" />
            <ContentControl Content="{TemplateBinding Content}" FontSize="{TemplateBinding FontSize}" FontFamily="{TemplateBinding FontFamily}" FontWeight="{TemplateBinding FontWeight}" />
            <ContentControl Content="{TemplateBinding Label}" FontSize="{TemplateBinding FontSize}" FontFamily="{TemplateBinding FontFamily}" FontWeight="{TemplateBinding FontWeight}" VerticalAlignment="Bottom" HorizontalAlignment="Left" Padding="10, 0, 0, 10" Margin="0, 0, 0, -5" />
          </Grid>
        </ControlTemplate>
      </Setter.Value>
    </Setter>
  </Style>
  <Style TargetType="local:OpacityToggleButton">
    <Setter Property="Foreground" Value="{StaticResource DefaultForegroundBrush}" />
    <Setter Property="Background" Value="{StaticResource DefaultForegroundBrush}" />
    <Setter Property="FontFamily" Value="{StaticResource FontFamilySegoeSemiBold}" />
    <Setter Property="FontSize" Value="{StaticResource DefaultFontSizeExtraSmall}" />
    <Setter Property="ButtonWidth" Value="{StaticResource DefaultAppButtonSize}" />
    <Setter Property="ButtonHeight" Value="{StaticResource DefaultAppButtonSize}" />
    <Setter Property="Template">
      <Setter.Value>
        <ControlTemplate TargetType="local:OpacityToggleButton">
          <Grid>
            <VisualStateManager.VisualStateGroups>
              <VisualStateGroup x:Name="CheckStates">
                <VisualState x:Name="Checked">
                  <Storyboard>
                    <DoubleAnimation Duration="{Binding AnimationDuration, RelativeSource={RelativeSource TemplatedParent}}" To="{Binding CheckedOpacity, RelativeSource={RelativeSource TemplatedParent}}" Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="ContentHost" />
                    <DoubleAnimation Duration="{Binding AnimationDuration, RelativeSource={RelativeSource TemplatedParent}}" To="{Binding CheckedOpacity, RelativeSource={RelativeSource TemplatedParent}}" Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="DisabledContentHost" />
                  </Storyboard>
                </VisualState>
                <VisualState x:Name="Unchecked">
                  <Storyboard>
                    <DoubleAnimation Duration="{Binding AnimationDuration, RelativeSource={RelativeSource TemplatedParent}}" To="{Binding UncheckedOpacity, RelativeSource={RelativeSource TemplatedParent}}" Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="ContentHost" />
                    <DoubleAnimation Duration="{Binding AnimationDuration, RelativeSource={RelativeSource TemplatedParent}}" To="{Binding UncheckedOpacity, RelativeSource={RelativeSource TemplatedParent}}" Storyboard.TargetProperty="(UIElement.Opacity)" Storyboard.TargetName="DisabledContentHost" />
                  </Storyboard>
                </VisualState>
                <VisualState x:Name="Indeterminate" />
              </VisualStateGroup>
              <VisualStateGroup x:Name="CommonStates">
                <VisualState x:Name="Normal" />
                <VisualState x:Name="Disabled">
                  <Storyboard>
                    <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility" Storyboard.TargetName="EnabledBackground">
                      <DiscreteObjectKeyFrame KeyTime="0">
                        <DiscreteObjectKeyFrame.Value>
                          <Visibility>Collapsed</Visibility>
                        </DiscreteObjectKeyFrame.Value>
                      </DiscreteObjectKeyFrame>
                    </ObjectAnimationUsingKeyFrames>
                    <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility" Storyboard.TargetName="DisabledBackground">
                      <DiscreteObjectKeyFrame KeyTime="0">
                        <DiscreteObjectKeyFrame.Value>
                          <Visibility>Visible</Visibility>
                        </DiscreteObjectKeyFrame.Value>
                      </DiscreteObjectKeyFrame>
                    </ObjectAnimationUsingKeyFrames>
                  </Storyboard>
                </VisualState>
              </VisualStateGroup>
            </VisualStateManager.VisualStateGroups>
            <Border Name="EnabledBackground" Height="{TemplateBinding Height}" Width="{TemplateBinding Width}" Padding="{TemplateBinding Padding}" BorderThickness="0" BorderBrush="Transparent" Background="Transparent">
              <StackPanel Orientation="{TemplateBinding Orientation}">
                <Grid Width="{TemplateBinding ButtonWidth}" Height="{TemplateBinding ButtonHeight}" Margin="0,-10, 0, 0">
                  <Grid Name="ContentHost">
                    <ContentControl Name="EnabledContent" Foreground="{TemplateBinding Background}" HorizontalContentAlignment="Center" VerticalContentAlignment="Center">
                      <Grid Name="EnabledHolder">
                        <ContentControl Name="ContentBody" Content="{TemplateBinding Content}" />
                      </Grid>
                    </ContentControl>
                  </Grid>
                </Grid>
                <ContentControl Name="ContentTitle" Margin="0, -5, 0 , 0" Content="{TemplateBinding Label}" Foreground="{TemplateBinding Foreground}" HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalContentAlignment="{TemplateBinding VerticalContentAlignment}" Style="{StaticResource AppBarText}" />
              </StackPanel>
            </Border>
            <Border Name="DisabledBackground" Height="{TemplateBinding Height}" Width="{TemplateBinding Width}" Padding="{TemplateBinding Padding}" BorderThickness="0" BorderBrush="Transparent" Background="Transparent" Visibility="Collapsed">
              <StackPanel Orientation="{TemplateBinding Orientation}">
                <Grid Width="{TemplateBinding ButtonWidth}" Height="{TemplateBinding ButtonHeight}" Margin="0,-10, 0, 0">
                  <Grid Name="DisabledContentHost">
                    <ContentControl Name="DisabledContent" Foreground="{StaticResource DefaultDisabledBrush}" HorizontalContentAlignment="Center" VerticalContentAlignment="Center">
                      <Grid Name="DisabledHolder" />
                    </ContentControl>
                  </Grid>
                </Grid>
                <ContentControl Content="{TemplateBinding Label}" Foreground="{StaticResource DefaultDisabledBrush}" HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalContentAlignment="{TemplateBinding VerticalContentAlignment}" Margin="{Binding Margin, ElementName=ContentTitle}" Style="{StaticResource AppBarText}" />
              </StackPanel>
            </Border>
          </Grid>
        </ControlTemplate>
      </Setter.Value>
    </Setter>
  </Style>
  <Style TargetType="local:RoundButton">
    <Setter Property="BorderBrush" Value="{StaticResource DefaultForegroundBrush}" />
    <Setter Property="Foreground" Value="{StaticResource DefaultForegroundBrush}" />
    <Setter Property="FontFamily" Value="{StaticResource FontFamilySegoeSemiBold}" />
    <Setter Property="PressedBrush" Value="{StaticResource DefaultAccentBrush}" />
    <Setter Property="FontSize" Value="{StaticResource DefaultFontSizeExtraSmall}" />
    <Setter Property="ButtonWidth" Value="{StaticResource DefaultAppButtonSize}" />
    <Setter Property="ButtonHeight" Value="{StaticResource DefaultAppButtonSize}" />
    <Setter Property="Template">
      <Setter.Value>
        <ControlTemplate TargetType="local:RoundButton">
          <Grid>
            <VisualStateManager.VisualStateGroups>
              <VisualStateGroup x:Name="CommonStates">
                <VisualState x:Name="Normal" />
                <VisualState x:Name="MouseOver" />
                <VisualState x:Name="Pressed">
                  <Storyboard>
                    <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Fill" Storyboard.TargetName="ButtonBackground">
                      <DiscreteObjectKeyFrame KeyTime="0" Value="{Binding PressedBrush, RelativeSource={RelativeSource TemplatedParent}}" />
                    </ObjectAnimationUsingKeyFrames>
                  </Storyboard>
                </VisualState>
                <VisualState x:Name="Disabled">
                  <Storyboard>
                    <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Stroke" Storyboard.TargetName="ButtonRing">
                      <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource DefaultDisabledBrush}" />
                    </ObjectAnimationUsingKeyFrames>
                    <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Fill" Storyboard.TargetName="ButtonBackground">
                      <DiscreteObjectKeyFrame KeyTime="0" Value="Transparent" />
                    </ObjectAnimationUsingKeyFrames>
                    <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Foreground" Storyboard.TargetName="ContentBody">
                      <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource DefaultDisabledBrush}" />
                    </ObjectAnimationUsingKeyFrames>
                    <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Foreground" Storyboard.TargetName="ContentTitle">
                      <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource DefaultDisabledBrush}" />
                    </ObjectAnimationUsingKeyFrames>
                  </Storyboard>
                </VisualState>
              </VisualStateGroup>
            </VisualStateManager.VisualStateGroups>
            <Border Name="EnabledBackground" Padding="{TemplateBinding Padding}" BorderThickness="0" BorderBrush="Transparent" Background="Transparent">
              <StackPanel Orientation="{TemplateBinding Orientation}">
                <Grid Width="{TemplateBinding ButtonWidth}" Height="{TemplateBinding ButtonHeight}" Margin="0,-10, 0, 0">
                  <Ellipse x:Name="ButtonBackground" Stroke="Transparent" Fill="{TemplateBinding Background}" Margin="10" />
                  <Grid Name="ContentHost">
                    <ContentControl Name="ContentBody" Content="{TemplateBinding Content}" Foreground="{TemplateBinding Foreground}" HorizontalContentAlignment="Center" VerticalContentAlignment="Center" />
                  </Grid>
                  <Ellipse x:Name="ButtonRing" Stroke="{TemplateBinding BorderBrush}" StrokeThickness="3" Fill="Transparent" Margin="10" />
                </Grid>
                <ContentControl x:Name="ContentTitle" Content="{TemplateBinding Label}" Foreground="{TemplateBinding Foreground}" HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalContentAlignment="{TemplateBinding VerticalContentAlignment}" Style="{StaticResource AppBarText}" />
              </StackPanel>
            </Border>
          </Grid>
        </ControlTemplate>
      </Setter.Value>
    </Setter>
  </Style>
  <Style TargetType="local:RoundToggleButton">
    <Setter Property="BorderBrush" Value="{StaticResource DefaultForegroundBrush}" />
    <Setter Property="Foreground" Value="{StaticResource DefaultForegroundBrush}" />
    <Setter Property="FontFamily" Value="{StaticResource FontFamilySegoeSemiBold}" />
    <Setter Property="CheckedBrush" Value="{StaticResource DefaultAccentBrush}" />
    <Setter Property="FontSize" Value="{StaticResource DefaultFontSizeExtraSmall}" />
    <Setter Property="ButtonWidth" Value="{StaticResource DefaultAppButtonSize}" />
    <Setter Property="ButtonHeight" Value="{StaticResource DefaultAppButtonSize}" />
    <Setter Property="Template">
      <Setter.Value>
        <ControlTemplate TargetType="local:RoundToggleButton">
          <Grid>
            <VisualStateManager.VisualStateGroups>
              <VisualStateGroup x:Name="CheckStates">
                <VisualState x:Name="Checked">
                  <Storyboard>
                    <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Fill" Storyboard.TargetName="ButtonBackground">
                      <DiscreteObjectKeyFrame KeyTime="0" Value="{Binding CheckedBrush, RelativeSource={RelativeSource TemplatedParent}}" />
                    </ObjectAnimationUsingKeyFrames>
                    <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Fill" Storyboard.TargetName="DisabledButtonBackground">
                      <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource DefaultDisabledBrush}" />
                    </ObjectAnimationUsingKeyFrames>
                    <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="StrokeThickness" Storyboard.TargetName="DisabledButtonRing">
                      <DiscreteObjectKeyFrame KeyTime="0" Value="0" />
                    </ObjectAnimationUsingKeyFrames>
                    <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Foreground" Storyboard.TargetName="DisabledContent">
                      <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource DefaultContrastDisabledBrush}" />
                    </ObjectAnimationUsingKeyFrames>
                  </Storyboard>
                </VisualState>
                <VisualState x:Name="Unchecked" />
                <VisualState x:Name="Indeterminate" />
              </VisualStateGroup>
              <VisualStateGroup x:Name="CommonStates">
                <VisualState x:Name="Normal" />
                <VisualState x:Name="Disabled">
                  <Storyboard>
                    <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility" Storyboard.TargetName="EnabledBackground">
                      <DiscreteObjectKeyFrame KeyTime="0">
                        <DiscreteObjectKeyFrame.Value>
                          <Visibility>Collapsed</Visibility>
                        </DiscreteObjectKeyFrame.Value>
                      </DiscreteObjectKeyFrame>
                    </ObjectAnimationUsingKeyFrames>
                    <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility" Storyboard.TargetName="DisabledBackground">
                      <DiscreteObjectKeyFrame KeyTime="0">
                        <DiscreteObjectKeyFrame.Value>
                          <Visibility>Visible</Visibility>
                        </DiscreteObjectKeyFrame.Value>
                      </DiscreteObjectKeyFrame>
                    </ObjectAnimationUsingKeyFrames>
                  </Storyboard>
                </VisualState>
              </VisualStateGroup>
            </VisualStateManager.VisualStateGroups>
            <Border Name="EnabledBackground" Height="{TemplateBinding Height}" Width="{TemplateBinding Width}" Padding="{TemplateBinding Padding}" BorderThickness="0" BorderBrush="Transparent" Background="Transparent">
              <StackPanel Orientation="{TemplateBinding Orientation}">
                <Grid Width="{TemplateBinding ButtonWidth}" Height="{TemplateBinding ButtonHeight}" Margin="0,-10, 0, 0">
                  <Ellipse x:Name="ButtonBackground" Stroke="Transparent" Fill="{TemplateBinding Background}" Margin="10" />
                  <Grid Name="ContentHost">
                    <ContentControl Name="EnabledContent" Foreground="{TemplateBinding Foreground}" HorizontalContentAlignment="Center" VerticalContentAlignment="Center">
                      <Grid Name="EnabledHolder">
                        <ContentControl Name="ContentBody" Content="{TemplateBinding Content}" />
                      </Grid>
                    </ContentControl>
                  </Grid>
                  <Ellipse x:Name="ButtonRing" Stroke="{TemplateBinding BorderBrush}" StrokeThickness="3" Fill="Transparent" Margin="10" />
                </Grid>
                <ContentControl Name="ContentTitle" Margin="0, -5, 0 , 0" Content="{TemplateBinding Label}" Foreground="{TemplateBinding Foreground}" HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalContentAlignment="{TemplateBinding VerticalContentAlignment}" Style="{StaticResource AppBarText}" />
              </StackPanel>
            </Border>
            <Border Name="DisabledBackground" Height="{TemplateBinding Height}" Width="{TemplateBinding Width}" Padding="{TemplateBinding Padding}" BorderThickness="0" BorderBrush="Transparent" Background="Transparent" Visibility="Collapsed">
              <StackPanel Orientation="{TemplateBinding Orientation}">
                <Grid Width="{TemplateBinding ButtonWidth}" Height="{TemplateBinding ButtonHeight}" Margin="0,-10, 0, 0">
                  <Ellipse x:Name="DisabledButtonBackground" Stroke="Transparent" Margin="10" />
                  <Grid Name="DisabledContentHost">
                    <ContentControl Name="DisabledContent" Foreground="{StaticResource DefaultDisabledBrush}" HorizontalContentAlignment="Center" VerticalContentAlignment="Center">
                      <Grid Name="DisabledHolder" />
                    </ContentControl>
                  </Grid>
                  <Ellipse x:Name="DisabledButtonRing" Stroke="{StaticResource DefaultDisabledBrush}" StrokeThickness="3" Fill="Transparent" Margin="10" />
                </Grid>
                <ContentControl Content="{TemplateBinding Label}" Foreground="{StaticResource DefaultDisabledBrush}" HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}" VerticalContentAlignment="{TemplateBinding VerticalContentAlignment}" Margin="{Binding Margin, ElementName=ContentTitle}" Style="{StaticResource AppBarText}" />
              </StackPanel>
            </Border>
          </Grid>
        </ControlTemplate>
      </Setter.Value>
    </Setter>
  </Style>
  <Style TargetType="local:Tile">
    <Setter Property="Background" Value="{StaticResource DefaultAccentBrush}" />
    <Setter Property="Foreground" Value="{StaticResource DefaultForegroundBrush}" />
    <Setter Property="FontSize" Value="{StaticResource DefaultFontSizeNormal}" />
    <Setter Property="Template">
      <Setter.Value>
        <ControlTemplate TargetType="local:Tile">
          <Grid Name="root" Background="{TemplateBinding Background}">
            <VisualStateManager.VisualStateGroups>
              <VisualStateGroup x:Name="CommonStates">
                <VisualState x:Name="Normal" />
                <VisualState x:Name="MouseOver" />
                <VisualState x:Name="Pressed" />
                <VisualState x:Name="PointerOver" />
                <VisualState x:Name="Disabled">
                  <Storyboard>
                    <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Foreground" Storyboard.TargetName="titleText">
                      <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource DefaultContrastDisabledBrush}" />
                    </ObjectAnimationUsingKeyFrames>
                    <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Foreground" Storyboard.TargetName="contentContainer">
                      <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource DefaultContrastDisabledBrush}" />
                    </ObjectAnimationUsingKeyFrames>
                    <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Background" Storyboard.TargetName="root">
                      <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource DefaultDisabledBrush}" />
                    </ObjectAnimationUsingKeyFrames>
                  </Storyboard>
                </VisualState>
              </VisualStateGroup>
            </VisualStateManager.VisualStateGroups>
            <ContentControl Name="contentContainer" HorizontalContentAlignment="Stretch" VerticalContentAlignment="Stretch" Content="{TemplateBinding Content}" />
            <!-- 
							Label is an object but TextWrapping is TextBlock Only
							... this could blow up 
						-->
            <TextBlock Name="titleText" TextWrapping="{TemplateBinding TextWrapping}" FontSize="{TemplateBinding FontSize}" FontFamily="{TemplateBinding FontFamily}" VerticalAlignment="Bottom" Padding="12, 0" Margin="0, 0, 0, 7" Text="{TemplateBinding Label}" />
          </Grid>
        </ControlTemplate>
      </Setter.Value>
    </Setter>
  </Style>
  <Style TargetType="local:TileNotification">
    <Setter Property="Background" Value="{StaticResource DefaultChromeBrush}" />
    <Setter Property="Foreground" Value="{StaticResource DefaultForegroundBrush}" />
    <Setter Property="FontWeight" Value="SemiBold" />
    <Setter Property="FontSize" Value="{StaticResource DefaultFontSizeNormal}" />
    <Setter Property="Margin" Value="5" />
    <Setter Property="Padding" Value="9, 0, 9, -1" />
    <Setter Property="VerticalAlignment" Value="Top" />
    <Setter Property="HorizontalAlignment" Value="Right" />
    <Setter Property="MinWidth" Value="28" />
    <Setter Property="MinHeight" Value="28" />
    <Setter Property="Template">
      <Setter.Value>
        <ControlTemplate TargetType="local:TileNotification">
          <Grid>
            <Rectangle Fill="{TemplateBinding Background}" RadiusX="14" RadiusY="14" />
            <ContentControl Margin="{TemplateBinding Padding}" Content="{TemplateBinding Content}" VerticalAlignment="Center" HorizontalAlignment="Center" />
          </Grid>
        </ControlTemplate>
      </Setter.Value>
    </Setter>
  </Style>
  <Style TargetType="local:ChatBubble">
    <Setter Property="Background" Value="{StaticResource DefaultAccentBrush}" />
    <Setter Property="FontFamily" Value="{StaticResource FontFamilySegoeNormal}" />
    <Setter Property="FontSize" Value="{StaticResource DefaultFontSizeMediumLarge}" />
    <Setter Property="BorderBrush" Value="{StaticResource DefaultAccentBrush}" />
    <Setter Property="BorderThickness" Value="{StaticResource DefaultBorderThickness}" />
    <Setter Property="Padding" Value="6, 2" />
    <Setter Property="HorizontalContentAlignment" Value="Left" />
    <Setter Property="Template">
      <Setter.Value>
        <ControlTemplate TargetType="local:ChatBubble">
          <Grid Background="Transparent">
            <VisualStateManager.VisualStateGroups>
              <VisualStateGroup x:Name="CommonStates">
                <VisualState x:Name="Normal" />
                <VisualState x:Name="MouseOver" />
                <VisualState x:Name="Disabled">
                  <Storyboard>
                    <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Background" Storyboard.TargetName="ContentBorder">
                      <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource DefaultDisabledBrush}" />
                    </ObjectAnimationUsingKeyFrames>
                    <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="BorderBrush" Storyboard.TargetName="ContentBorder">
                      <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource DefaultDisabledBrush}" />
                    </ObjectAnimationUsingKeyFrames>
                    <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Fill" Storyboard.TargetName="LowerRightPath">
                      <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource DefaultDisabledBrush}" />
                    </ObjectAnimationUsingKeyFrames>
                    <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Fill" Storyboard.TargetName="LowerLeftPath">
                      <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource DefaultDisabledBrush}" />
                    </ObjectAnimationUsingKeyFrames>
                    <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Fill" Storyboard.TargetName="UpperRightPath">
                      <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource DefaultDisabledBrush}" />
                    </ObjectAnimationUsingKeyFrames>
                    <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Fill" Storyboard.TargetName="UpperLeftPath">
                      <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource DefaultDisabledBrush}" />
                    </ObjectAnimationUsingKeyFrames>
                  </Storyboard>
                </VisualState>
              </VisualStateGroup>
              <VisualStateGroup x:Name="ChatBubbleDirectionStates">
                <VisualState x:Name="UpperRight">
                  <Storyboard>
                    <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility" Storyboard.TargetName="UpperRightPath">
                      <DiscreteObjectKeyFrame KeyTime="0">
                        <DiscreteObjectKeyFrame.Value>
                          <Visibility>Visible</Visibility>
                        </DiscreteObjectKeyFrame.Value>
                      </DiscreteObjectKeyFrame>
                    </ObjectAnimationUsingKeyFrames>
                  </Storyboard>
                </VisualState>
                <VisualState x:Name="UpperLeft">
                  <Storyboard>
                    <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility" Storyboard.TargetName="UpperLeftPath">
                      <DiscreteObjectKeyFrame KeyTime="0">
                        <DiscreteObjectKeyFrame.Value>
                          <Visibility>Visible</Visibility>
                        </DiscreteObjectKeyFrame.Value>
                      </DiscreteObjectKeyFrame>
                    </ObjectAnimationUsingKeyFrames>
                  </Storyboard>
                </VisualState>
                <VisualState x:Name="LowerRight">
                  <Storyboard>
                    <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility" Storyboard.TargetName="LowerRightPath">
                      <DiscreteObjectKeyFrame KeyTime="0">
                        <DiscreteObjectKeyFrame.Value>
                          <Visibility>Visible</Visibility>
                        </DiscreteObjectKeyFrame.Value>
                      </DiscreteObjectKeyFrame>
                    </ObjectAnimationUsingKeyFrames>
                  </Storyboard>
                </VisualState>
                <VisualState x:Name="LowerLeft">
                  <Storyboard>
                    <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility" Storyboard.TargetName="LowerLeftPath">
                      <DiscreteObjectKeyFrame KeyTime="0">
                        <DiscreteObjectKeyFrame.Value>
                          <Visibility>Visible</Visibility>
                        </DiscreteObjectKeyFrame.Value>
                      </DiscreteObjectKeyFrame>
                    </ObjectAnimationUsingKeyFrames>
                  </Storyboard>
                </VisualState>
              </VisualStateGroup>
            </VisualStateManager.VisualStateGroups>
            <Grid.RowDefinitions>
              <RowDefinition Height="Auto" />
              <RowDefinition Height="Auto" />
              <RowDefinition Height="Auto" />
            </Grid.RowDefinitions>
            <Border x:Name="ContentBorder" Grid.Row="1" Padding="{TemplateBinding Padding}" BorderThickness="{TemplateBinding BorderThickness}" BorderBrush="{TemplateBinding BorderBrush}" Background="{TemplateBinding Background}">
              <ContentControl HorizontalContentAlignment="{TemplateBinding HorizontalContentAlignment}" Margin="{StaticResource DefaultTextBoxInnerMargin}" Content="{TemplateBinding Content}" FontSize="{TemplateBinding FontSize}" FontFamily="{TemplateBinding FontFamily}" />
            </Border>
            <Path Name="LowerRightPath" Data="M0,0 L1,1 L1,0 " Grid.Row="2" Fill="{TemplateBinding BorderBrush}" Stretch="Fill" Margin="12,0" Height="12" Width="18" Visibility="Collapsed" HorizontalAlignment="Right" />
            <Path Name="LowerLeftPath" Data="M0,0 L0,1 L1,0" Grid.Row="2" Fill="{TemplateBinding BorderBrush}" Stretch="Fill" Margin="12,0" Height="12" Width="18" Visibility="Collapsed" HorizontalAlignment="Left" />
            <Path Name="UpperLeftPath" Data="M0,0 L1,1 L0,1 " Grid.Row="0" Fill="{TemplateBinding BorderBrush}" Stretch="Fill" Margin="12,0" Height="12" Width="18" Visibility="Collapsed" HorizontalAlignment="Left" />
            <Path Name="UpperRightPath" Data="M0,1 L1,1 L1,0 " Grid.Row="0" Fill="{TemplateBinding BorderBrush}" Stretch="Fill" Margin="12,0" Height="12" Width="18" Visibility="Collapsed" HorizontalAlignment="Right" />
          </Grid>
        </ControlTemplate>
      </Setter.Value>
    </Setter>
  </Style>
  <Style TargetType="local:ChatBubbleTextBox">
    <Setter Property="FontFamily" Value="{StaticResource FontFamilySegoeNormal}" />
    <Setter Property="FontSize" Value="{StaticResource DefaultFontSizeMediumLarge}" />
    <Setter Property="Background" Value="{StaticResource DefaultTextBoxBrush}" />
    <Setter Property="Foreground" Value="{StaticResource DefaultTextBoxForegroundBrush}" />
    <Setter Property="BorderBrush" Value="{StaticResource DefaultTextBoxBrush}" />
    <Setter Property="BorderThickness" Value="{StaticResource DefaultBorderThickness}" />
    <Setter Property="Padding" Value="7, 4, 0, 4" />
    <Setter Property="ScrollViewer.HorizontalScrollBarVisibility" Value="Hidden" />
    <Setter Property="ScrollViewer.VerticalScrollBarVisibility" Value="Hidden" />
    <Setter Property="ScrollViewer.IsDeferredScrollingEnabled" Value="False" />
    <Setter Property="Template">
      <Setter.Value>
        <ControlTemplate TargetType="local:ChatBubbleTextBox">
          <Grid>
            <VisualStateManager.VisualStateGroups>
              <VisualStateGroup x:Name="ChatBubbleDirectionStates">
                <VisualState x:Name="UpperRight">
                  <Storyboard>
                    <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility" Storyboard.TargetName="UpperRightPath">
                      <DiscreteObjectKeyFrame KeyTime="0">
                        <DiscreteObjectKeyFrame.Value>
                          <Visibility>Visible</Visibility>
                        </DiscreteObjectKeyFrame.Value>
                      </DiscreteObjectKeyFrame>
                    </ObjectAnimationUsingKeyFrames>
                  </Storyboard>
                </VisualState>
                <VisualState x:Name="UpperLeft">
                  <Storyboard>
                    <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility" Storyboard.TargetName="UpperLeftPath">
                      <DiscreteObjectKeyFrame KeyTime="0">
                        <DiscreteObjectKeyFrame.Value>
                          <Visibility>Visible</Visibility>
                        </DiscreteObjectKeyFrame.Value>
                      </DiscreteObjectKeyFrame>
                    </ObjectAnimationUsingKeyFrames>
                  </Storyboard>
                </VisualState>
                <VisualState x:Name="LowerRight">
                  <Storyboard>
                    <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility" Storyboard.TargetName="LowerRightPath">
                      <DiscreteObjectKeyFrame KeyTime="0">
                        <DiscreteObjectKeyFrame.Value>
                          <Visibility>Visible</Visibility>
                        </DiscreteObjectKeyFrame.Value>
                      </DiscreteObjectKeyFrame>
                    </ObjectAnimationUsingKeyFrames>
                  </Storyboard>
                </VisualState>
                <VisualState x:Name="LowerLeft">
                  <Storyboard>
                    <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility" Storyboard.TargetName="LowerLeftPath">
                      <DiscreteObjectKeyFrame KeyTime="0">
                        <DiscreteObjectKeyFrame.Value>
                          <Visibility>Visible</Visibility>
                        </DiscreteObjectKeyFrame.Value>
                      </DiscreteObjectKeyFrame>
                    </ObjectAnimationUsingKeyFrames>
                  </Storyboard>
                </VisualState>
              </VisualStateGroup>
              <VisualStateGroup x:Name="CommonStates">
                <VisualState x:Name="Disabled">
                  <Storyboard>
                    <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Background" Storyboard.TargetName="BackgroundElement">
                      <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource TextBoxDisabledBackgroundThemeBrush}" />
                    </ObjectAnimationUsingKeyFrames>
                    <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="BorderBrush" Storyboard.TargetName="BorderElement">
                      <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource TextBoxDisabledBorderThemeBrush}" />
                    </ObjectAnimationUsingKeyFrames>
                    <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Foreground" Storyboard.TargetName="ContentElement">
                      <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource TextBoxDisabledForegroundThemeBrush}" />
                    </ObjectAnimationUsingKeyFrames>
                  </Storyboard>
                </VisualState>
                <VisualState x:Name="Normal">
                  <Storyboard>
                    <DoubleAnimation Duration="0" To="{StaticResource TextControlBackgroundThemeOpacity}" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="BackgroundElement" />
                    <DoubleAnimation Duration="0" To="{StaticResource TextControlBorderThemeOpacity}" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="BorderElement" />
                  </Storyboard>
                </VisualState>
                <VisualState x:Name="PointerOver">
                  <Storyboard>
                    <DoubleAnimation Duration="0" To="{StaticResource TextControlPointerOverBackgroundThemeOpacity}" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="BackgroundElement" />
                    <DoubleAnimation Duration="0" To="{StaticResource TextControlPointerOverBorderThemeOpacity}" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="BorderElement" />
                  </Storyboard>
                </VisualState>
                <VisualState x:Name="Focused">
                  <Storyboard>
                    <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="BorderBrush" Storyboard.TargetName="BorderElement">
                      <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource DefaultAccentBrush}" />
                    </ObjectAnimationUsingKeyFrames>
                  </Storyboard>
                </VisualState>
              </VisualStateGroup>
              <VisualStateGroup x:Name="ButtonStates">
                <VisualState x:Name="ButtonVisible">
                  <Storyboard>
                    <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility" Storyboard.TargetName="DeleteButton">
                      <DiscreteObjectKeyFrame KeyTime="0">
                        <DiscreteObjectKeyFrame.Value>
                          <Visibility>Visible</Visibility>
                        </DiscreteObjectKeyFrame.Value>
                      </DiscreteObjectKeyFrame>
                    </ObjectAnimationUsingKeyFrames>
                  </Storyboard>
                </VisualState>
                <VisualState x:Name="ButtonCollapsed" />
              </VisualStateGroup>
            </VisualStateManager.VisualStateGroups>
            <Grid.RowDefinitions>
              <RowDefinition Height="Auto" />
              <RowDefinition Height="Auto" />
              <RowDefinition Height="Auto" />
            </Grid.RowDefinitions>
            <Grid Grid.Row="1">
              <Grid.Resources>
                <Style x:Name="DeleteButtonStyle" TargetType="Button">
                  <Setter Property="Template">
                    <Setter.Value>
                      <ControlTemplate TargetType="Button">
                        <Grid>
                          <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup x:Name="CommonStates">
                              <VisualState x:Name="Normal" />
                              <VisualState x:Name="PointerOver">
                                <Storyboard>
                                  <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Background" Storyboard.TargetName="BackgroundElement">
                                    <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource TextBoxButtonPointerOverBackgroundThemeBrush}" />
                                  </ObjectAnimationUsingKeyFrames>
                                  <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="BorderBrush" Storyboard.TargetName="BorderElement">
                                    <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource TextBoxButtonPointerOverBorderThemeBrush}" />
                                  </ObjectAnimationUsingKeyFrames>
                                  <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Foreground" Storyboard.TargetName="GlyphElement">
                                    <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource TextBoxButtonPointerOverForegroundThemeBrush}" />
                                  </ObjectAnimationUsingKeyFrames>
                                </Storyboard>
                              </VisualState>
                              <VisualState x:Name="Pressed">
                                <Storyboard>
                                  <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Background" Storyboard.TargetName="BackgroundElement">
                                    <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource TextBoxButtonPressedBackgroundThemeBrush}" />
                                  </ObjectAnimationUsingKeyFrames>
                                  <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="BorderBrush" Storyboard.TargetName="BorderElement">
                                    <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource TextBoxButtonPressedBorderThemeBrush}" />
                                  </ObjectAnimationUsingKeyFrames>
                                  <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Foreground" Storyboard.TargetName="GlyphElement">
                                    <DiscreteObjectKeyFrame KeyTime="0" Value="{StaticResource TextBoxButtonPressedForegroundThemeBrush}" />
                                  </ObjectAnimationUsingKeyFrames>
                                </Storyboard>
                              </VisualState>
                              <VisualState x:Name="Disabled">
                                <Storyboard>
                                  <DoubleAnimation Duration="0" To="0" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="BackgroundElement" />
                                  <DoubleAnimation Duration="0" To="0" Storyboard.TargetProperty="Opacity" Storyboard.TargetName="BorderElement" />
                                </Storyboard>
                              </VisualState>
                            </VisualStateGroup>
                          </VisualStateManager.VisualStateGroups>
                          <Border Name="BorderElement" BorderBrush="{StaticResource TextBoxButtonBorderThemeBrush}" BorderThickness="{TemplateBinding BorderThickness}" />
                          <Border Name="BackgroundElement" Background="{StaticResource TextBoxButtonBackgroundThemeBrush}" Margin="{TemplateBinding BorderThickness}">
                            <TextBlock Name="GlyphElement" Foreground="{StaticResource TextBoxButtonForegroundThemeBrush}" FontFamily="{StaticResource SymbolThemeFontFamily}" HorizontalAlignment="Center" Text="" VerticalAlignment="Center" />
                          </Border>
                        </Grid>
                      </ControlTemplate>
                    </Setter.Value>
                  </Setter>
                </Style>
              </Grid.Resources>
              <Grid.ColumnDefinitions>
                <ColumnDefinition Width="*" />
                <ColumnDefinition Width="Auto" />
              </Grid.ColumnDefinitions>
              <Border Name="BackgroundElement" Background="{TemplateBinding Background}" Margin="{TemplateBinding BorderThickness}" Grid.ColumnSpan="2" />
              <Border Name="BorderElement" Background="Transparent" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Grid.ColumnSpan="2" />
              <TextBlock Opacity="0" Text="{TemplateBinding Text}" Margin="{TemplateBinding BorderThickness}" Padding="{TemplateBinding Padding}" />
              <ScrollViewer Name="HintContentElement" Foreground="{StaticResource DefaultTextBoxReadOnlyBrush}" Content="{TemplateBinding Hint}" HorizontalScrollMode="{TemplateBinding ScrollViewer.HorizontalScrollMode}" HorizontalScrollBarVisibility="{TemplateBinding ScrollViewer.HorizontalScrollBarVisibility}" IsTabStop="False" IsHorizontalRailEnabled="{TemplateBinding ScrollViewer.IsHorizontalRailEnabled}" IsVerticalRailEnabled="{TemplateBinding ScrollViewer.IsVerticalRailEnabled}" IsDeferredScrollingEnabled="{TemplateBinding ScrollViewer.IsDeferredScrollingEnabled}" Margin="{TemplateBinding BorderThickness}" Padding="{TemplateBinding Padding}" VerticalScrollBarVisibility="{TemplateBinding ScrollViewer.VerticalScrollBarVisibility}" VerticalScrollMode="{TemplateBinding ScrollViewer.VerticalScrollMode}" ZoomMode="Disabled" />
              <ScrollViewer Name="ContentElement" HorizontalScrollMode="{TemplateBinding ScrollViewer.HorizontalScrollMode}" HorizontalScrollBarVisibility="{TemplateBinding ScrollViewer.HorizontalScrollBarVisibility}" IsTabStop="False" IsHorizontalRailEnabled="{TemplateBinding ScrollViewer.IsHorizontalRailEnabled}" IsVerticalRailEnabled="{TemplateBinding ScrollViewer.IsVerticalRailEnabled}" IsDeferredScrollingEnabled="{TemplateBinding ScrollViewer.IsDeferredScrollingEnabled}" Margin="{TemplateBinding BorderThickness}" Padding="{TemplateBinding Padding}" VerticalScrollBarVisibility="{TemplateBinding ScrollViewer.VerticalScrollBarVisibility}" VerticalScrollMode="{TemplateBinding ScrollViewer.VerticalScrollMode}" ZoomMode="Disabled" />
              <Button Name="DeleteButton" Style="{StaticResource DeleteButtonStyle}" BorderThickness="{TemplateBinding BorderThickness}" FontSize="{TemplateBinding FontSize}" IsTabStop="False" Visibility="Collapsed" VerticalAlignment="Stretch" Grid.Column="1" />
            </Grid>
            <Path Name="LowerRightPath" Data="M0,0 L1,1 L1,0 " Grid.Row="2" Fill="{Binding ElementName=BorderElement, Path=BorderBrush}" Opacity="{Binding ElementName=BorderElement, Path=Opacity}" Stretch="Fill" Margin="12,0" Height="12" Width="18" Visibility="Collapsed" HorizontalAlignment="Right" VerticalAlignment="Top" />
            <Path Name="LowerLeftPath" Data="M0,0 L0,1 L1,0" Grid.Row="2" Fill="{Binding ElementName=BorderElement, Path=BorderBrush}" Opacity="{Binding ElementName=BorderElement, Path=Opacity}" Stretch="Fill" Margin="12,0" Height="12" Width="18" Visibility="Collapsed" HorizontalAlignment="Left" VerticalAlignment="Top" />
            <Path Name="UpperLeftPath" Data="M0,0 L1,1 L0,1 " Grid.Row="0" Fill="{Binding ElementName=BorderElement, Path=BorderBrush}" Opacity="{Binding ElementName=BorderElement, Path=Opacity}" Stretch="Fill" Margin="12,0" Height="12" Width="18" Visibility="Collapsed" HorizontalAlignment="Left" VerticalAlignment="Bottom" />
            <Path Name="UpperRightPath" Data="M0,1 L1,1 L1,0 " Grid.Row="0" Fill="{Binding ElementName=BorderElement, Path=BorderBrush}" Opacity="{Binding ElementName=BorderElement, Path=Opacity}" Stretch="Fill" Margin="12,0" Height="12" Width="18" Visibility="Collapsed" HorizontalAlignment="Right" VerticalAlignment="Bottom" />
          </Grid>
        </ControlTemplate>
      </Setter.Value>
    </Setter>
  </Style>
  <Style TargetType="local:ColorHexagonPicker">
    <Setter Property="VerticalAlignment" Value="Center" />
    <Setter Property="HorizontalAlignment" Value="Center" />
    <Setter Property="Template">
      <Setter.Value>
        <ControlTemplate TargetType="local:ColorHexagonPicker">
          <StackPanel>
            <ContentPresenter Content="{TemplateBinding ColorBody}" />
            <ContentPresenter Content="{TemplateBinding GreyScaleBody}" />
          </StackPanel>
        </ControlTemplate>
      </Setter.Value>
    </Setter>
  </Style>
</ResourceDictionary>
